<%@ page language="java" contentType="text/html; charset=utf-8"
         pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
    String path = request.getContextPath() + "/";
%>
<!DOCTYPE HTML>
<html>
<head>
    <title>忘记密码</title>
    <link href="css/style.css" rel="stylesheet" type="text/css" media="all" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport"
          content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <!-- -->
    <script>
        var __links = document.querySelectorAll('a');
        function __linkClick(e) {
            parent.window.postMessage(this.href, '*');
        };
        for (var i = 0, l = __links.length; i < l; i++) {
            if (__links[i].getAttribute('data-t') == '_blank') {
                __links[i].addEventListener('click', __linkClick, false);
            }
        }
    </script>
    <script src="<%=path%>/js/jquery.js"></script>
    <script>
        $(document).ready(function(c) {
            $('.alert-close').on('click', function(c) {
                $('.message').fadeOut('slow', function(c) {
                    $('.message').remove();
                });
            });
        });
    </script>
</head>
<body>
<!-- contact-form -->
<div class="message warning">
    <div class="inset">
        <div class="login-head">
            <h1>找回密码</h1>
            <div class="alert-close"></div>
        </div>
        <form action="forget.do" method="post" id="form_forget">
            <li><input name="username" type="text" class="text" placeholder="请输入用户名" id="username">
            </li>
            <li><input name="mail" type="text" placeholder="请输入验证邮箱" id="mail">
            </li>
            <div class="clear"></div>
            <div class="submit">
                <input type="button" value="找回密码"  id="forget">
                <h4>
                    <a href="index.jsp" style="float: right">返回登录</a>
                </h4>
                <br>
<%--                <input type="hidden" id="get_password" value="${mail}">--%>
                <br> <span style="color: red; font-size: 10px" id="get_password" >${MSG}</span>
                <div class="clear"></div>
            </div>
        </form>
    </div>
</div>
<div style="display: none">
    <script src='http://v7.cnzz.com/stat.php?id=155540&web_id=155540'
            language='JavaScript' charset='gb2312'></script>
</div>
</body>
<script src="js/jquery.js"></script>
<script>
    $("#forget").click(function () {
        var username=$("#username").val();
        var mail=$("#mail").val();
        if(username==''||username==null||username==undefined){
            alert("请输入用户名！");
        }
        else if(mail==''||mail==null||mail==undefined){
            alert("请输入邮箱！");
        }
        else{
            $("#form_forget").submit();
        }
    })
    // if($("#get_password").val()!=''&&$("#get_password").val()!=undefined){
    //     alert($("#get_password").val());
    //     $("#get_password").val("");
    // }
</script>
</html>